package cfdt.ldl.trade.controller.lawyer;

import cfdt.common.vo.ObjectBaseResponse;
import cfdt.ldl.trade.api.request.AddLawyerTradeRequest;
import cfdt.ldl.trade.api.request.GetLawyerInfoListTradeRequest;
import cfdt.ldl.trade.service.lawyer.LawyerTradeService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;


@RestController
@RequestMapping("/lawyer")
public class LawyerTradeController {

    @Autowired
    private LawyerTradeService lawyerTradeService;

    @GetMapping("/addLawyer")
    public ObjectBaseResponse addLawyer(@RequestBody AddLawyerTradeRequest request) throws Exception {
        return lawyerTradeService.addLawyer(request);
    }

    @GetMapping("/getLawyerInfoList")
    public ObjectBaseResponse getLawyerInfoList(@RequestBody GetLawyerInfoListTradeRequest request) {
        return lawyerTradeService.getLawyerInfoList(request);
    }

}
